using System;
using System.Collections;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using Customer;


namespace WindowsFormsApplication1
{
    public partial class BeveragePourType : Form
    {
        string cardNum;
        Person person;
        BitArray status;
        BeverageSizeSelect SizeSelect;
        public BeveragePourType(Person person1, BitArray Status)
        {
            person = person1;
            cardNum = person.CardNumber;
            status = Status;
            InitializeComponent();            
        }

        // Clicked Select Size
        private void selectSize_Click(object sender, EventArgs e)
        {
            // set bit three to indicate order is predetermined size
            status[0] = true;
            status[1] = false;
            status[3] = true;
            BeverageSizeSelect beerSizeSelect = new BeverageSizeSelect(person, status);
            this.Close();            
            beerSizeSelect.ShowDialog();            
        }

        private void payPerOunce_Click(object sender, EventArgs e)
        {
            // clear bit three to indicate that this is a pay per oz order
            status[0] = true;
            status[1] = false;
            status[2] = false;
            status[3] = false;
            status[4] = false;
            status[5] = false;
            status[6] = false;
            status[7] = false;
            StartAndStopPour startAndStop = new StartAndStopPour(person, status, SizeSelect);
            this.Close();
            startAndStop.ShowDialog();           
        }

        private void cancelButton_Click(object sender, EventArgs e)
        {
            this.Close();
        }        
    }
}
